<form id="add-form" class="form-horizontal" role="form" data-toggle="validator" method="POST" action="">

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Ad_position_id')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-ad_position_id" data-rule="required" min="0" data-source="jieziad/ad_position/index" class="form-control selectpage" name="row[ad_position_id]" type="text" value="">
        </div>
    </div>
    <!--<div class="form-group">-->
        <!--<label class="control-label col-xs-12 col-sm-2">{:__('Media_type')}:</label>-->
        <!--<div class="col-xs-12 col-sm-8">-->
            <!--<input id="c-media_type" data-rule="required" min="0" class="form-control" name="row[media_type]" type="number" value="0">-->
        <!--</div>-->
    <!--</div>-->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Ad_name')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-ad_name" data-rule="required" class="form-control" name="row[ad_name]" type="text" value="">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Ad_type')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-ad_type" min="0" data-primary-key="sign" data-source="jieziad/ad_type/index" class="form-control selectpage" name="row[ad_type]" type="text" value="">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Ad_val')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-ad_val" class="form-control" name="row[ad_val]" type="text">
        </div>
        <p class="help-block">{:__('Ad_val_desc')}</p>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Ad_image')}:</label>
        <div class="col-xs-12 col-sm-8">
            <div class="input-group">
                <input id="c-ad_image" data-rule="required" class="form-control" size="50" name="row[ad_image]" type="textarea">
                <div class="input-group-addon no-border no-padding">
                    <span><button type="button" id="faupload-ad_image" class="btn btn-danger faupload" data-input-id="c-ad_image" data-mimetype="image/gif,image/jpeg,image/png,image/jpg,image/bmp" data-multiple="false" data-preview-id="p-ad_image"><i class="fa fa-upload"></i> {:__('Upload')}</button></span>
                    <span><button type="button" id="fachoose-ad_image" class="btn btn-primary fachoose" data-input-id="c-ad_image" data-mimetype="image/*" data-multiple="false"><i class="fa fa-list"></i> {:__('Choose')}</button></span>
                </div>
                <span class="msg-box n-right" for="c-ad_image"></span>
            </div>
            <ul class="row list-inline faupload-preview" id="p-ad_image"></ul>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Start_time')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-start_time" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[start_time]" type="text" value="">
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('End_time')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-end_time" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[end_time]" type="text" value="">
        </div>
    </div>
    <!--<div class="form-group">-->
        <!--<label class="control-label col-xs-12 col-sm-2">{:__('Click_count')}:</label>-->
        <!--<div class="col-xs-12 col-sm-8">-->
            <!--<input id="c-click_count" data-rule="required" min="0" class="form-control" name="row[click_count]" type="number" value="0">-->
        <!--</div>-->
    <!--</div>-->
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Enabled_switch')}:</label>
        <div class="col-xs-12 col-sm-8">
            {:build_radios('row[enabled_switch]', ['1'=>__('Yes'), '0'=>__('No')], 1)}
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Weigh')}:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-weigh" data-rule="required" class="form-control" name="row[weigh]" type="number" value="50">
        </div>
    </div>
    <!--<div class="form-group">-->
        <!--<label class="control-label col-xs-12 col-sm-2">{:__('Target')}:</label>-->
        <!--<div class="col-xs-12 col-sm-8">-->
            <!--<input id="c-target" data-rule="required" class="form-control" name="row[target]" type="number" value="0">-->
        <!--</div>-->
    <!--</div>-->
    <div class="form-group layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
